@import "compass/css3";
/* Variables */
$color: #4a89dc;
$black: #333; /* Generic */
body {
    font-family: "open sans", "helvetica neue", helvetica, arial, sans-serif;
    background: url('../images/main-background.jpg') repeat;
    > .row {
        max-width: 100%;
    }
}
h1 {
    font-family: "source sans pro", "helvetica neue", helvetica, arial, sans-serif;
}
button, .button, a, span, li, .head-area:after, hr, img, .read-more:before, main, .post, .head-area {
    @include transition(.3s all);
}
a {
    color: $color;
    &:hover {
        color: darken($color, 20%);
    }
}
#outdated {
    display: none;
}

/* Foundation row */
.row {
    max-width: 72.5em;
}

/* Topbar for mobile */
.top-bar {
    background: none;
    overflow: visible;
    z-index: 9998;
    height: 50px;
    line-height: 50px;
    .home {
        display: block;
        position: absolute;
        top: 0;
        left: 0;
        background: rgba(51, 51, 51, 0.8);
        .fi-home {
            color: white;
            position: relative;
            display: block;
            padding: 0 15px;
            width: 50px;
            height: 50px;
            line-height: 50px;
            font-size: 2rem;
        }
    }
    .toggle-topbar {
        display: block;
        background: rgba(51, 51, 51, 0.8);
        .fi-list {
            width: 50px;
            height: 50px;
            line-height: 50px;
            font-size: 2rem;
        }
    }
    li a:hover {
        background: $color;
    }
    .top-bar-section {
        .right {
            li {
                /* @media screen and (min-width:40.063em) {
                    border-left: 1px solid left;
                }
                */
            }
        }
    }
    &:hover + .row .head-area:after {
        background: rgba(51, 51, 51, 0.65);
    }
    &:hover + .row hr {
        border-color: white;
        width: 200px;
    }
}

/* Social network */
.blog-network {
    padding-bottom: 15px;
    float: right;
    @media screen and (min-width:64.063em) {
        margin-top: 2em;
    }
    a {
        float: right;
        background: rgba(51, 51, 51, 0.8);
        color: white;
        width: 36px;
        height: 36px;
        line-height: 36px;
        font-size: 26px;
        margin: 0;
        &:hover {
            background: $color;
            margin-left: 7px;
            margin-right: 7px;
            @include border-radius(50px);
        }
        &:first-of-type:hover {
            margin-right: 0;
        }
        &:last-of-type:hover {
            margin-left: 0;
        }
    }
}

/* Sidebar */
.head-area {
    margin-top: -50px;
    padding-top: 30px;
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
    background-color: $color;
    &:not(.bgimage) {
        &:hover {
            background: darken($color, 40%);
        }
        &:after {
            display: none;
            background: none;
        }
    }
    hr {
        border-color: $black;
    }
    &:hover {
        &.bgimage:after {
            background: rgba(51, 51, 51, 0.65);
        }
        hr {
            border-color: white;
            width: 200px;
        }
    }
    &:after {
        content: "";
        position: absolute;
        width: 100%;
        height: 100%;
        top: 0;
        left: 0;
        z-index: 1;
        background: rgba(0, 0, 0, 0.8);
    }
    @media screen and (min-width:64.063em) {
        margin-top: 0;
        padding: 0 1.1rem;
        position: fixed;
        right: 0;
        top: 0;
        bottom: 0;
    }
}
.site-head {
    text-align: center;
    z-index: 2;
    position: relative;
    .blog-description {
        margin: 1.3rem 0 1rem;
        color: white;
        font-weight: 300;
    }
    .blog-logo {
        display: inline-block;
        @include transition(.3s);
        img {
            width: 100px;
            height: 100px;
            border: 2px solid white;
            @include border-radius(100px);
        }
        &:hover {
            @include transform(scale(1.1));
        }
    }
    .blog-title {
        margin: 0.7rem 0 1rem;
        font-weight: 400;
        text-transform: uppercase;
        color: white;
        line-height: 1;
      font-size: 2rem;
      float: left;
      width: 100%;
      text-align: center;
    }
    hr {
        width: 100px;
        margin: 0 auto;
    }
    .blog-menu {
        float: left;
        clear: both;
        width: 100%;
        margin-bottom: 35px;
        @media screen and (min-width:100em) {
            float: right;
        }
        li {
            font-size: 1rem;
            width: 32%;
            float: left;
            @media screen and (min-width:100em) {
                width: 18%;
                &:nth-child(1) {
                    margin-left: 42%;
                }
            }
            &:nth-child(2) {
                margin: 0 2%;
            }
            &:hover {
            }
            a {
                padding: 5px 0;
                background: $black;
                color: white;
                text-transform: uppercase;
                font-size: 2rem;
                &:hover {
                    color: white;
                    background: $color;
                }
            }
        }
    }
}

/* * Crazy overlay menu * */
/* Overlay style */
.overlay {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background: rgba($black, 0.89);
    z-index: 9999;
}

/* Overlay closing cross */
.overlay .overlay-close {
    width: 80px;
    height: 80px;
    position: absolute;
    right: 0;
    top: 0;
    overflow: hidden;
    border: none;
    background: url(../images/cross.png) no-repeat center center;
    text-indent: 200%;
    color: transparent;
    outline: none;
    z-index: 100;
}

/* Menu style */
.overlay nav {
    text-align: center;
    position: relative;
    top: 50%;
    height: 60%;
    -webkit-transform: translateY(-50%);
    transform: translateY(-50%);
}
.overlay ul {
    list-style: none;
    padding: 0;
    margin: 0 auto;
    display: inline-block;
    height: 100%;
    position: relative;
}
.overlay ul li {
    display: block;
    height: 30%;
    min-height: 54px;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
}
.overlay ul li a {
    font-size: 54px;
    font-weight: 300;
    display: block;
    color: #fff;
    padding: 0 20px;
}
.overlay ul li a:hover, .overlay ul li a:focus {
    background: $color;
}

/* Effects */
.overlay-scale {
    visibility: hidden;
    opacity: 0;
    -webkit-transform: scale(0.9);
    transform: scale(0.9);
    -webkit-transition: -webkit-transform 0.2s, opacity 0.2s, visibility 0s 0.2s;
    transition: transform 0.2s, opacity 0.2s, visibility 0s 0.2s;
}
.overlay-scale.open {
    visibility: visible;
    opacity: 1;
    -webkit-transform: scale(1);
    transform: scale(1);
    -webkit-transition: -webkit-transform 0.4s, opacity 0.4s;
    transition: transform 0.4s, opacity 0.4s;
}
@media screen and (max-height:30.5em) {
    .overlay nav {
        height: 70%;
        font-size: 34px;
    }
    .overlay ul li {
        min-height: 34px;
    }
}
.main-column {
    main {
        max-width: 800px;
        margin: 0 auto;
        padding: 1.5rem 0;
        @media screen and (max-width:64.063em) {
            max-width: none;
            width: 100%;
        }
        @media screen and (min-width:64.063em) {
            padding: 1.5rem 0;
        }
        @media screen and (min-width:100em) {
            padding: 4rem 0;
            max-width: 1100px;
        }
    }
    @media screen and (min-width:64.063em) {
        position: absolute;
        height: 100%;
    }
    .pagination {
        position: relative;
        text-align: center;
        background: $black;
        border-bottom: 4px solid $color;
        a {
            position: absolute;
            font-size: 1.5rem;
            color: white;
            background: $black;
            &:first-child {
                left: 0;
            }
            &:last-child {
                right: 0;
            }
            &:hover {
                color: $color;
                background: #fff;
            }
        }
        .page-number {
            font-size: 1.1rem;
            font-weight: 300;
            line-height: 54px;
            color: #fff;
        }
    }
}

/* POST */
.post {
    background: #fff;
    overflow: hidden;
    padding: 1.5em;
    margin-bottom: 1.5rem;
    border-bottom: $color 2px solid;
    position: relative;
    @include box-shadow(0 0 25px 0 rgba(0, 0, 0, 0.1));
    @media screen and (min-width:64.063em) {
        padding: 2.5em;
        margin-bottom: 1.5rem;
    }
    @media screen and (min-width:100em) {
        margin-bottom: 3rem;
        padding: 2.5em 3.5em;
    }
    p {
        font-size: 0.9rem;
        line-height: 2;
    }
    .read-more {
        margin-bottom: 0;
        background: $color;
        padding: 0.7rem 1.6rem;
        border-radius: 3px;
        width: 100%;
        font-weight: bold;
        font-size: 0.9rem;
        text-transform: uppercase;
        @media screen and (min-width:40.063em) {
            margin-left: 15px;
            width: auto;
        }
        &:before {
            content: "\f16c";
            content: "\f16c";
            font-family: "foundation-icons";
            font-style: normal;
            font-weight: normal;
            font-variant: normal;
            text-transform: none;
            line-height: 1;
            -webkit-font-smoothing: antialiased;
            display: inline-block;
            text-decoration: inherit;
            color: white;
            position: absolute;
            font-size: 2em;
            left: 50%;
            top: -50%;
            @include translateY(-50%);
            margin-left: -11px;
            @include opacity(0);
        }
        &:hover {
            background: darken($color, 5%);
            border-radius: 7px;
            color: darken($color, 5%);
            &:before {
                top: 50%;
                @include opacity(1);
            }
        }
    }
    .tags {
        &:before {
            font-size: 1.7rem;
            padding-right: 8px;
            vertical-align: middle;
        }
        float: left;
        font-size: 0.8em;
        margin: 10px 0;
        color: #BEBEBE;
        line-height: 1.6;
        @media screen and (max-width:40.063em) {
            line-height: 27px;
        }
        a {
            text-transform: uppercase;
            color: $color;
            &:hover {
                color: darken($color, 20%);
                border-bottom: 1px solid darken($color, 20%);
            }
        }
    }
    .post-title {
        font-weight: 400;
        color: $black;
        line-height: 1.2;
        margin: 1rem 0 1.2rem;
        a {
            color: inherit;
            &:hover {
                color: $color;
            }
        }
    }
    header {
        .post-meta {
            position: absolute;
            top: 0;
            left: 0;
            background: #C7C7C7;
            color: white;
            padding: 5px 10px;
            font-size: 14px;
        }
    }
}
.post-template {
    .post {
        .post-title {
            margin: -1.5em;
            background: $color;
            color: white;
            margin: -1.5rem -1.5rem 0;
            padding: 1.5rem;
            @media screen and (min-width:64.063em) {
                margin: -2.5rem -2.5rem 0;
            }
            @media screen and (min-width:100em) {
                margin: -2.5rem -3.5rem 0;
            }
        }
        .post-meta {
            float: right;
            background: none;
            font-size: 0.8rem;
            line-height: 20px;
            margin: -30px -1.5rem 0;
            padding: 0.3rem 0.7rem;
            @media screen and (min-width:64.063em) {
                margin-right: -2.5rem;
            }
            @media screen and (min-width:100em) {
                margin-right: -3.5rem;
            }
            time {
                color: white;
            }
        }
        .post-content {
            padding-top: 1.5rem;
            @media screen and (min-width:64.063em) {
                padding-top: -2.5rem;
            }
            @media screen and (min-width:100em) {
                padding-top: -3.5rem;
            }
        }
        pre {
            margin: 1.6em 0;
            box-sizing: border-box;
            background: #f1f0ea;
            border: 1px solid #dddbcc;
            width: 100%;
            padding: 10px;
            font-family: Inconsolata, monospace;
            font-size: 0.9em;
            white-space: pre;
            overflow: auto;
            border-radius: 3px;
            word-wrap: break-word;
            code {
                font-size: inherit;
                white-space: -moz-pre-wrap;
                white-space: pre-wrap;
                background: transparent;
                border: none;
                padding: 0;
                font-family: Inconsolata, monospace;
                border-radius: 2px;
                line-height: 1.5;
            }
        }
        .share {
            @media screen and (min-width:64.063em) {
                width: 50%;
                float: left;
                margin-top: 0;
            }
            .fi-social-facebook {
                color: #3b5998
            }
            .fi-social-twitter {
                color: #00aced
            }
            .fi-social-google-plus {
                color: #dd4b39
            }
            a {
                margin-right: 10px;
                font-size: 2.5rem;
                &:hover {
                    color: darken($color, 10%);
                }
            }
        }
        .author {
            background: $color;
            margin-top: 20px;
            color: white;
            width: 100%;
            border-radius: 8px;
            border-bottom: 2px solid darken($color, 15%);
            text-align: center;
            line-height: 2.3;
            @media screen and (min-width:64.063em) {
                width: 50%;
                float: right;
                margin-top: 0;
            }
            header {
                span {
                    color: darken($color, 12%);
                    font-size: 1.4rem;
                    font-weight: 900;
                    font-family: "source sans pro", arial, sans-serif;
                    text-transform: uppercase;
                }
            }
            section {
                background: rgb(238, 238, 238);
                position: relative;
                overflow: hidden;
                padding: 10px;
                h4 {
                    margin: 0;
                    text-align: left;
                    padding-right: 100px;
                    color: $black;
                    font-weight: 700;
                    float: left;
                    clear: both;
                }
                span {
                    text-align: left;
                    color: lighten($black, 10%);
                    float: left;
                    clear: both;
                    font-size: 0.8rem;
                    line-height: 1.2;
                    padding: 10px 100px 10px 0;
                }
                img {
                    position: absolute;
                    right: -10px;
                    max-width: 120px;
                    height: 100%;
                    max-height: 120px;
                    bottom: 0;
                }
                a {
                    text-align: left;
                    padding-right: 100px;
                    color: $color;
                    float: left;
                    clear: both;
                    font-size: 0.8rem;
                    line-height: 1.2;
                    &:hover {
                        color: darken($color, 20%);
                        text-decoration: underline;
                    }
                }
            }
            footer {
                padding: 10px;
                p {
                    margin: 0;
                    text-align: left;
                    font-size: 0.8rem;
                    line-height: 1.6;
                }
            }
        }
    }
}

/* featuredRED */
.post.featured {
    .home-template &, .tag-template & {
        padding: 0;
    }
    > a {
        margin: 0;
        position: relative;
        iframe, embed {
            width: 100% !important;
            @include box-shadow(0 2px 10px 0 rgba(0, 0, 0, 0.2));
        }
        p {
            font-size: 0;
            margin-bottom: 0;
            img {
                width: 100%;
                height: auto;
                @include box-shadow(0 2px 10px 0 rgba(0, 0, 0, 0.2));
                &:hover {
                    @include box-shadow(0 2px 10px 0 rgba(0, 0, 0, 0.5));
                }
            }
        }
    }
    > div {
        padding: 1.5em;
        @media screen and (min-width:64.063em) {
            padding: 2.5em;
        }
        @media screen and (min-width:100em) {
            padding: 2.5em 3.5em;
        }
        .post-header {
            .post-meta {
                background: $color;
            }
            h2 {
                margin-top: 0;
            }
        }
    }
}

/* FOOTER */
.site-footer {
    section {
        font-size: 0.8rem;
        margin-top: 1rem;
        text-align: center;
        @media screen and (min-width:64.063em) {
            width: 33%;
            float: left;
        }
        a {
            color: $color;
            &:hover {
                text-decoration: underline;
                color: darken($color, 10%);
            }
        }
    }
}

/* DISQUS */
.title-disqus {
    margin: 20px 0;
    span:before {
        padding-right: 10px;
    }
}